# encoding: utf-8
"""
Created on 2020-10-12

@author: xuzh
"""
import os.path
import yaml

# 获取 etls/conf/params.yaml 参数文件中的参数
setting_file_path = os.path.abspath(__file__)
CONFS_FILE_PATH = setting_file_path.replace("settings.py", "confs.yaml")
confs = yaml.load(open(CONFS_FILE_PATH, encoding='utf-8'), Loader=yaml.FullLoader)
db_config_path = setting_file_path.replace("settings.py", "db.ini")
default_db_cd = 'dw'
log_level = 'INFO'
# dcetl根目录所在路径
if 'BASE_DIR' in confs:
    BASE_DIR = confs['BASE_DIR']
else:
    BASE_DIR = setting_file_path.replace("/conf/settings.py", "")
